package com.psq.business.login.repository

import com.psq.base.user.model.User
import com.psq.core.common.model.ApiResponse
import com.psq.core.common.network.BaseRepository
import com.psq.business.login.network.api.LoginService
import javax.inject.Inject

class LoginRepository @Inject constructor(private val loginService: LoginService) :
    BaseRepository(), LoginService {

    override suspend fun loginByPassword(params: MutableMap<String, Any>): ApiResponse<User> {
        return apiCall { loginService.loginByPassword(params) }
    }


    override suspend fun logout(params: MutableMap<String, Any>): ApiResponse<Any> {
        return apiCall { loginService.logout(params) }
    }

}